--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -141,7 +141,6 @@ find_package_auto(ENABLE_LIBUNINAMESLIST  Libuninameslist)
 find_package_auto(ENABLE_LIBGIF           GIF)
 find_package_auto(ENABLE_LIBJPEG          JPEG)
 find_package_auto(ENABLE_LIBPNG           PNG)
-find_package_auto(ENABLE_LIBREADLINE      Readline)
 find_package_auto(ENABLE_LIBTIFF          TIFF)
 find_package_auto(ENABLE_WOFF2            WOFF2)
 find_package_auto(ENABLE_CODE_COVERAGE    Gcov)
--- a/cmake/FontForgeConfigure.cmake
+++ b/cmake/FontForgeConfigure.cmake
@@ -95,7 +95,6 @@ function(fontforge_generate_config template destination)
   _set_negated(_NO_LIBUNGIF "${ENABLE_LIBGIF_RESULT}")
   _set_negated(_NO_LIBUNINAMESLIST "${ENABLE_LIBUNINAMESLIST_RESULT}")
   _set_negated(_NO_PYTHON "${ENABLE_PYTHON_SCRIPTING_RESULT}")
-  _set_negated(_NO_LIBREADLINE "${ENABLE_LIBREADLINE_RESULT}")
 
   if(ENABLE_LIBSPIRO_RESULT)
     set(_LIBSPIRO_FUN ${Libspiro_FEATURE_LEVEL})
--- a/fontforge/CMakeLists.txt
+++ b/fontforge/CMakeLists.txt
@@ -255,9 +255,7 @@ endif()
 if(ENABLE_LIBUNINAMESLIST_RESULT)
   target_link_libraries(fontforge PUBLIC Libuninameslist::Libuninameslist)
 endif()
-if(ENABLE_LIBREADLINE_RESULT)
-  target_link_libraries(fontforge PUBLIC Readline::Readline)
-endif()
+target_link_libraries(fontforge PUBLIC edit)
 if(ENABLE_PYTHON_SCRIPTING_RESULT)
   target_link_libraries(fontforge PRIVATE Python3::Python)
 endif()
--- a/fontforge/scripting.c
+++ b/fontforge/scripting.c
@@ -98,8 +98,7 @@
 # include <ieeefp.h>		/* Solaris defines isnan in ieeefp rather than math.h */
 #endif
 #ifndef _NO_LIBREADLINE
-# include <readline/history.h>
-# include <readline/readline.h>
+# include <editline/readline.h>
 #endif
 
 int no_windowing_ui = false;
